#ifndef CTABLEVIEW_H
#define CTABLEVIEW_H

#include <QWidget>
#include <QPushButton>
#include <QTableWidget>
#include <QLabel>
#include <QLineEdit>
#include <QVBoxLayout>
#include <QGridLayout>

#include <QHeaderView>
#include <QAxObject>
#include <QToolBar>




class CChartView;

class CTableView : public QWidget
{
    Q_OBJECT
public:
    explicit CTableView(QWidget *parent = nullptr);

    QPushButton*        m_pPointcloud;   //生成点云图

private:
    QGridLayout *       gridLayout;
    QVBoxLayout*        m_pVboxLay;

    QToolBar*           m_pMybar1;
    QToolBar*           m_pMybar2;

    QPushButton*        m_pChoice;  //xuanzhewenjian
    QLineEdit*          m_pFileName;
    QPushButton*        m_pAddDate;  //加载数据
    QPushButton*        m_pDaochuDate;  //导出


    QLabel*             m_pSearch;
    QLineEdit*          m_pSearchLine;
    QTableWidget*       m_pDateTable;  //表格

    QString             directory;


    CChartView*         m_pChartView;  //


signals:



private:
    void excel_read(QString &path,QTableWidget *tablewidget);
    void excel_write(QString &path, QTableWidget *tablewidget);
    void Qvariant2listlistVariant(const QVariant &var,QList<QList<QVariant>> &ret);
    void castListListVariant2Variant(const QList<QList<QVariant> > &cells, QVariant &res);

    void ScreenInfo(QTableWidget *source, QString &text);


private slots:
    void slot_Adddata();
    void slot_ChoiceFile();
    void slot_createPointcloud();
    void slot_searchByText();
    void slot_moveOutdata();


};

#endif // CTABLEVIEW_H
